package com.bird.multipleevent;

import org.springframework.context.ApplicationListener;

/**
 * @data 2023/4/8 11:22
 * @author: bird
 * @description: 黄色事件监听器
 */
public class YellowAccidentEventListener implements ApplicationListener<YellowAccidentEvent> {
    @Override
    public void onApplicationEvent(YellowAccidentEvent yellowAccidentEvent) {
        System.out.println("发生了黄色事故: "+yellowAccidentEvent.getSource());
    }
}
